Skip to content

Feature: Experimental compositor display scale detection for sharper text on niri - #147

Merged
MemerGamer merged 1 commit into
mainfrom
linux/niri-scale
Oct 10, 2026
Merged

MemerGamer merged 1 commit into
mainfrom
linux/niri-scale

Conversation

@MemerGamer

Copy link
Copy Markdown
Owner

Resolved / Related Issues

No linked issue was provided.

Changes

Adds Detect display scale from the compositor (experimental) to Settings > Appearance on Linux. It defaults off and requires a restart. When enabled on niri / xwayland-satellite without existing display or toolkit scale hints, Files reads the focused output's scale before Uno starts, using niri IPC with a bounded CLI fallback. Missing focus falls back to the first output. Detection failures preserve existing behavior; startup detection does not track movement between outputs. Some configurations may double-scale.

Existing hints retain precedence: UNO_DISPLAY_SCALE_OVERRIDE, Xft.dpi, GDK_SCALE / GDK_DPI_SCALE, and QT_SCALE_FACTOR / QT_SCREEN_SCALE_FACTORS, including explicit 1x or malformed hints, prevent niri fallback. Both NIRI_SOCKET and WAYLAND_DISPLAY must be present. After those hints, FILES_NIRI_SCALE=1 forces detection on and FILES_NIRI_SCALE=0 forces it off, overriding the saved preference; other values use the saved toggle. For a manual scale, launch with UNO_DISPLAY_SCALE_OVERRIDE=1.25 files, replacing 1.25 with the output scale.

Steps used to test these changes

  1. Built tests/Files.Platform.Tests with -warnaserror, -m:2, node reuse disabled, and low priority under flock ~/.cache/linuxfiles-agents/build.lock: passed with zero warnings or errors.
  2. Ran the complete Files.Platform.Tests suite outside the restricted sandbox, under the same lock and at low priority, with real display variables removed: 1,238 passed, 0 failed, 0 skipped. The earlier socket/bubblewrap/thumbnail failures did not recur. X11 integration tests use private Xvfb displays.
  3. Built src/Files.App -f net10.0-desktop -nodeReuse:false -m:2 with MSBUILDDISABLENODEREUSE=1, low priority, and the shared lock: passed with zero warnings or errors on this incremental build.
  4. git diff --check, CRLF checks, append-only resource validation, and XML/XAML parsing passed. Previous work also verified 64 focused scale/settings tests and CLI timeout/output limits with process cleanup.

No real display was used. Visual confirmation on the reporter's compositor remains unverified.

Claude-Session: https://claude.ai/code/session_016FAtbHHLQSiJiYcw2vnKiq

Co-Authored-By: GPT-6.1-sol (OpenAI Codex) noreply@openai.com

🤖 Generated with Claude Code

https://claude.ai/code/session_016FAtbHHLQSiJiYcw2vnKiq

Co-Authored-By: GPT-6.1-sol (OpenAI Codex) <noreply@openai.com>
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_016FAtbHHLQSiJiYcw2vnKiq
@MemerGamer
MemerGamer merged commit b21ce5d into main Oct 10, 2026
3 checks passed
@MemerGamer
MemerGamer deleted the linux/niri-scale branch October 10, 2026 05:59
MemerGamer added a commit that referenced this pull request Oct 10, 2026
Preserve release preparation and include PRs #144-#147 in the release
highlights, with the remaining scaling, selection and read-only tag limits.

Co-Authored-By: GPT-6.1-sol (OpenAI Codex) <noreply@openai.com>
Claude-Session: https://claude.ai/code/session_016FAtbHHLQSiJiYcw2vnKiq
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant